package com.yootk.jdbc.service;

import com.yootk.jdbc.vo.Book;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
import org.springframework.stereotype.Service;

@Service
public class PubService {
    @Autowired
    private IBookService service ;
    public Boolean editAll() {
        Book bookA = new Book() ;
        bookA.setTitle(null);
        bookA.setAuthor("米氏");
        bookA.setPrice(85.6);
        Book bookB = new Book() ;
        bookB.setTitle("湖北");
        bookB.setAuthor("武汉");
        bookB.setPrice(74.0);
        bookB.setBid(12L);
        return this.service.add(bookA) && this.service.edit(bookB) ;
    }
}
